import { lazy } from 'react'

const AddPack = lazy(() => import('../../views/Index/Sale/AddPack')) 
const SelectGoods = lazy(() => import('../../views/Index/Sale/SelectGoods')) 
const Pack = lazy(() => import('../../views/Index/Sale/Pack')) 
const Account = lazy(() => import('../../views/Index/Finance/Account')) 
const Bill = lazy(() => import('../../views/Index/Finance/Bill')) 
const Recharge = lazy(() => import('../../views/Index/Finance/Recharge')) 
const Accounts = lazy(() => import('../../views/Index/Sale/Accounts')) 
const Sale = lazy(() => import('../../views/Index/Sale'))
const Finance = lazy(() => import('../../views/Index/Finance'))
const AddGoods = lazy(() => import('../../views/Index/Sale/addGoods'))
const AddAccount = lazy(() => import('../../views/Index/Sale/AddAccount'))
export default [
    {
        path: '/index/sale',
        element: <Sale />,
        children:[
            {
                path:'/index/sale/selectgoods',
                element:<SelectGoods />
            },
            {
                path:'/index/sale/addgoods',
                element:<AddGoods />
            },
            {
                path:'/index/sale/pack',
                element:<Pack />
            },
            {
                path:'/index/sale/addpack',
                element:<AddPack />
            },
            {
                path:'/index/sale/accounts',
                element:<Accounts />
            },
            {
                path:'/index/sale/addaccount',
                element:<AddAccount />
            },
        ]
    },
    {
        path: '/index/finance',
        element: <Finance />,
        children:[
            {
                path:'/index/finance/account',
                element:<Account />
            },
            {
                path:'/index/finance/bill',
                element:<Bill />
            },
            {
                path:'/index/finance/recharge',
                element:<Recharge />
            },
        ]
    },
]